Skip to content

Add missing one-click login to OMP 3.4#2291

Merged
asmecher merged 1 commit into
pkp:stable-3_4_0from
ajnyga:fixOneClick
Jun 15, 2026
Merged

Add missing one-click login to OMP 3.4#2291
asmecher merged 1 commit into
pkp:stable-3_4_0from
ajnyga:fixOneClick

Conversation

@ajnyga

@ajnyga ajnyga commented Apr 1, 2026

Copy link
Copy Markdown
Contributor

In OMP 3.4 the one click reviewer access seems to be broken. The email contains a link that looks ok, there is also corresponding line in access_keys. However, the link leads to the login page. In OJS 3.4 the one-click links works.

Seems that it is not handled at all in OMP 3.4
https://github.com/pkp/omp/blob/stable-3_4_0/pages/reviewer/ReviewerHandler.php

OJS 3.4 has the required handling
https://github.com/pkp/ojs/blob/stable-3_4_0/pages/reviewer/ReviewerHandler.php

This pr introduces the similar logic to OMP 3.4.

@asmecher

asmecher commented Apr 1, 2026

Copy link
Copy Markdown
Member

@defstat, could you have a look at this one, both the PR for stable-3_4_0 and to check whether this needs attention in stable-3_5_0 and main, where it'll be relying instead on the invitation toolset?

@ajnyga

ajnyga commented Apr 2, 2026

Copy link
Copy Markdown
Contributor Author

Getting failed tests but with errors that seem unrelated.

@ajnyga

ajnyga commented Apr 23, 2026

Copy link
Copy Markdown
Contributor Author

Any information about this? Thinking mainly whether the changes in overall seem good since I would like to have this in our production site.

@defstat

defstat commented Apr 30, 2026

Copy link
Copy Markdown
Contributor

@defstat, could you have a look at this one, both the PR for stable-3_4_0 and to check whether this needs attention in stable-3_5_0 and main, where it'll be relying instead on the invitation toolset?

@asmecher @ajnyga sorry for the delay on this.

This does not need porting to stable-3_5_0 and main branches, in my opinion - the one-click feature is handled by invitations after 3.5.0, and the respective code is already in the public function authorize($request, &$args, $roleAssignments) function of the ReviewerHandler class.

@ajnyga

ajnyga commented May 6, 2026

Copy link
Copy Markdown
Contributor Author

Thanks! Agreed that no porting needed, it was rewritten and also OMP had the same logic in 3.5+.
@asmecher I restarted the tests, not sure what caused them to fail the last time since I do not think one-click is used in the tests.

@asmecher asmecher left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for the wait, @ajnyga!

I did catch an issue that's also present in the OJS code. Would you mind changing it here, and opening a PR in OJS as well? (No good deed goes unpunished.)

Comment thread pages/reviewer/ReviewerHandler.php Outdated
@ajnyga

ajnyga commented Jun 15, 2026

Copy link
Copy Markdown
Contributor Author

The requested OJS pr here pkp/ojs#5596

@asmecher asmecher merged commit 35d1c61 into pkp:stable-3_4_0 Jun 15, 2026
17 of 20 checks passed
@asmecher

Copy link
Copy Markdown
Member

Thanks, @ajnyga!

@Tribunal33, this is merged to stable-3_4_0 (and only that branch!) and ready for QA.

@Tribunal33

Tribunal33 commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

@asmecher wild didn't know you could add a PR to my QA project. Anyways this passes -- Tested on OMP 3.4. Do we want to create a formal ticket to capture this? I tried both with this selected and not selected. Enabled, it jumps right to the review and disabled it goes to login page. Looks like the email stays the same regardless of the setting so to have the key associated with the email you will need to have the setting enabled first. The email will not allow for one time click when the email contains a link before setting was enabled.

Tests.

  1. Test that the One click reviewer setting is enabled.
  2. Add a reviewer
  3. Use link with incognito to jump right to review

  1. Test that the One click reviewer setting is disabled and email already has one-click key
  2. Use link with incognito should redirect to login page

  1. Test that the One click reviewer setting is disabled
  2. Add a reviewer
  3. Use the link with incognito it should redirect to login page.
  4. Now turn the One click reviewer setting to Enabled
  5. Use the email link again from the same user
  6. Should still redirect to login page becuase there is no one-click key in the URL link.
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants